## kill Main Install if Terminate = $true
if ($env:terminate -eq $true) {exit 0}

Write-Host -ForegroundColor Yellow "Creating Default Site Collection."

function createSite(){

	$site = get-spsite

	if ($site -eq $null){
	Write-Host "Default Site Collection does not exist, creating..."
	$web = Get-SPWebApplication
	New-SPSite $env:farmurl -OwnerAlias $env:serviceacct -Name $env:farmname -Template "STS#0"
	}

	
}

createSite

Write-Host -ForegroundColor Yellow "Creating Default Site Collection. COMPLETED"
